package cn.grf.datasource.config;

/**
 * @author grf
 * @apiNote 动态数据源 - 未测试
 * @since 2025/5/6
 */
@Deprecated
public class DataSourceContextHolder {
    // 使用 ThreadLocal 保存当前数据源标识
    private static final ThreadLocal<String> contextHolder = new ThreadLocal<>();
    public static void setDataSourceKey(String key) { contextHolder.set(key); }
    public static String getDataSourceKey() { return contextHolder.get(); }
    public static void clear() { contextHolder.remove(); }
}
